package org.daidai.abstrusewriting.homepage.classify.model;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.List;

/**
 * Created by Administrator on 2016/11/1.
 */

public class TabItemList implements Parcelable{
    private List<TabItem> tabItems;

    public TabItemList() {
    }

    protected TabItemList(Parcel in) {
        tabItems = in.createTypedArrayList(TabItem.CREATOR);
    }

    public static final Creator<TabItemList> CREATOR = new Creator<TabItemList>() {
        @Override
        public TabItemList createFromParcel(Parcel in) {
            return new TabItemList(in);
        }

        @Override
        public TabItemList[] newArray(int size) {
            return new TabItemList[size];
        }
    };

    public List<TabItem> getTabItems() {
        return tabItems;
    }

    public void setTabItems(List<TabItem> tabItems) {
        this.tabItems = tabItems;
    }

    @Override
    public String toString() {
        return "TabItemList{" +
                "tabItems=" + tabItems +
                '}';
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeTypedList(tabItems);
    }
}
